package com.niguang.govt.admin.api.entity;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableLogic;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * <p>
 *
 * </p>
 *
 * @author 12380
 * @since 2018-12-13
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("work_reform_user")
public class ReformUser extends Model<ReformUser> {

    public static final String ID = "id";
    public static final String SITE_ID = "site_id";
    public static final String USER_ID = "user_id";
    public static final String USER_NAME = "user_name";
    public static final String USER_PHONE = "user_phone";
    public static final String JOB_POSITION = "job_position";
    public static final String ROLE_TYPE = "role_type";
    public static final String UNION_ID = "union_id";
    public static final String OPEN_ID = "open_id";
    public static final String CREATE_TIME = "create_time";
    public static final String UPDATE_TIME = "update_time";
    public static final String DEL_FLAG = "del_flag";
    public static final String ROLE_DESC = "role_desc";
    private static final long serialVersionUID = 1L;
    private Long id;
    /**
     * 工地ID
     */
    private Long siteId;
    private Long userId;
    /**
     * 用户姓名
     */
    private String userName;
    /**
     * 手机号码
     */
    private String userPhone;
    /**
     * 工作职位
     */
    private String jobPosition;
    /**
     * 1--整改人 2--审核人
     */
    private Integer roleType;
    /**
     * 微信unionId
     */
    private String unionId;
    /**
     * 微信服务号openId
     */
    private String openId;
    @TableField(fill = FieldFill.INSERT)
    private LocalDateTime createTime;
    @TableField(fill = FieldFill.INSERT_UPDATE)
    private LocalDateTime updateTime;
    /**
     * 删除标识 0-未删除 1-已删除
     */
    @TableLogic
    private Integer delFlag;
    /**
     * 角色描述 整改人  审核人  复查人
     */
    private String roleDesc;

    @Override
    protected Serializable pkVal() {
        return this.id;
    }

}
